package javaFeatures.src.TestFeature.oopcourse;

public class Student {
    private String name;
    private String studentID;
    private String className;
    private String gender;
    private int age;
    private String personality;

    public Student(String n, String id, String cls, String gen, int a, String per) {
        this.name = n;
        this.studentID = id;
        this.className = cls;
        this.gender = gen;
        this.age = a;
        this.personality = per;
    }

    public String getName() {
        return name;
    }

    public String getStudentID() {
        return studentID;
    }

    public String getClassName() {
        return className;
    }

    public String getGender() {
        return gender;
    }

    public int getAge() {
        return age;
    }

    public String getPersonality() {
        return personality;
    }

    public String infoSummary() {
        return "姓名: " + name + ", 学号: " + studentID + ", 班级: " + className +
                ", 性别: " + gender + ", 年龄: " + age + ", 性格: " + personality;
    }

    public static void main(String[] args) {
        Student student1 = new Student("张三", "202301", "母猪产后护理", "男", 20, "油饼");
        Student student2 = new Student("李四", "202302", "互联网农民工", "女", 21, "幽默");
        Student student3 = new Student("王五", "202303", "外卖资源管理", "未知", 22, "抽象"); // 假设"？"在Java中用"未知"代替

        System.out.println(student1.infoSummary());
        System.out.println(student2.infoSummary());
        System.out.println(student3.infoSummary());
    }
}
